package com.jy.wms.web;


import com.jy.wms.service.SysMenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("/Disqualification")
public class Disqualification {

    @Autowired
    SysMenuService menuService;

    //主页面
    @RequestMapping(value = "/Disqualification/{menu}")
    public String Disqualification(@PathVariable("menu") String menu, Model model) {
        model.addAttribute("functions",menuService.getFunctions(menu));
        return "Disqualification/Disqualification";
    }

    /*@RequestMapping(value = "/unqualified")
    public String unqualified(String id, Model model){
        model.addAttribute("id",id);
        return "/Disqualification/unqualifiedwarehousing";
    }*/

    @RequestMapping(value = "/unqualified")
    public String unqualified(String id, Model model){
        model.addAttribute("id",id);
        return "Disqualification/unqualifiedwarehousing";
    }

    /*@RequestMapping(value = "/Warehousing")
    public String Warehousing(String id, Model model){
        model.addAttribute("id",id);
        return "/Disqualification/Warehousing";
    }*/

    @RequestMapping(value = "/Warehousing")
    public String Warehousing(String id, Model model){
        model.addAttribute("id",id);
        return "Disqualification/Warehousing";
    }

    /*@RequestMapping(value = "/addkuwei")
    public String addkuwei(String id, Model model){
        model.addAttribute("id",id);
        return "/Disqualification/addkuwei";
    }*/

    @RequestMapping(value = "/addkuwei")
    public String addkuwei(String id, Model model){
        model.addAttribute("id",id);
        return "Disqualification/addkuwei";
    }
}
